package com.neusoft.feign;

import com.neusoft.po.CommonResult;
import com.neusoft.po.Food;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;

@FeignClient(name="food-server",fallback = FeignClientCallBack.class)//指定调用的食品微服务名
public interface FoodFeignClient {

    @GetMapping("/FoodController/getFoodById/{businessId}/{foodId}")
    public CommonResult<Food> getFoodById(@PathVariable("businessId") Integer businessId,
                                          @PathVariable("foodId") Integer foodId);
}
